Publish CI test results into PR discussions and harden artifact download action#570
Publish CI test results into PR discussions and harden artifact download action#570Copilot wants to merge 9 commits into
Conversation
0523a39 to
7894f66
Compare
…ory` and remove external server orchestration from build (#564) Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Andrii Chebukin <XperiAndri@Outlook.com>
…compile time (#569) Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Andrii Chebukin <XperiAndri@Outlook.com>
7894f66 to
52c17c5
Compare
There was a problem hiding this comment.
Pull request overview
Adds CI-driven PR test result publishing by producing TRX test artifacts in the build, uploading them from PR runs, and adding a privileged workflow_run publisher to report results back to PRs.
Changes:
- Configures
dotnet testto emit TRX files intotest-results. - Uploads event payload and test-result artifacts from the PR workflow.
- Adds a new workflow to download artifacts and publish test results to PR checks/discussions.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
build/Program.fs |
Adds TRX logger/results directory configuration for the unit test runner. |
.github/workflows/pull-request.yml |
Adds explicit permissions and uploads PR event/test result artifacts. |
.github/workflows/publish-test-results.yml |
Adds workflow-run based test result publishing using downloaded artifacts. |
| uses: EnricoMi/publish-unit-test-result-action@v2 | ||
| with: | ||
| commit: ${{ github.event.workflow_run.head_sha }} | ||
| event_file: ${{ steps.event_file.outputs.path }} | ||
| event_name: ${{ github.event.workflow_run.event }} | ||
| files: "test-results/**/*.trx" |
There was a problem hiding this comment.
It means the workflow would publish only a check unless PR comment publishing is enabled/configured. I updated it in commit 1cf3cef by setting comment_mode: always, so PR discussion comments are explicitly enabled. No UI changes were made, so there is no screenshot.
There was a problem hiding this comment.
It means PR-discussion comments were not explicitly configured in the publish step. Commit 1cf3cef now sets comment_mode: always, making PR commenting explicit alongside check publication. No UI changes were made, so there is no screenshot.
| with: | ||
| run_id: ${{ github.event.workflow_run.id }} | ||
| path: test-results | ||
| pattern: test-results-* |
There was a problem hiding this comment.
Yes — that was true. dawidd6/action-download-artifact uses name (optionally with name_is_regexp), not pattern. I fixed this in commit 1cf3cef by switching to name: ^test-results-.* and name_is_regexp: true. No UI changes were made, so there is no screenshot.
There was a problem hiding this comment.
Yes, it was true. The previous input was ineffective for that action. Commit 1cf3cef updates it to supported inputs (name + name_is_regexp) so only test-result artifacts are matched. No UI changes were made, so there is no screenshot.
Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Andrii Chebukin <XperiAndri@Outlook.com>
Agent-Logs-Url: https://github.com/fsprojects/FSharp.Data.GraphQL/sessions/ae314b8b-9c8a-4f87-a8b0-b77c4bfa2cef Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com>
Agent-Logs-Url: https://github.com/fsprojects/FSharp.Data.GraphQL/sessions/ae314b8b-9c8a-4f87-a8b0-b77c4bfa2cef Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com>
Agent-Logs-Url: https://github.com/fsprojects/FSharp.Data.GraphQL/sessions/ae314b8b-9c8a-4f87-a8b0-b77c4bfa2cef Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com>
Agent-Logs-Url: https://github.com/fsprojects/FSharp.Data.GraphQL/sessions/aa451f1b-8f2c-4148-b6fe-ac4d6356af9f Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com>
Agent-Logs-Url: https://github.com/fsprojects/FSharp.Data.GraphQL/sessions/75e24ea8-3ef8-4ff9-b896-387e88504c2a Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com>
9545f0c to
857933c
Compare
Agent-Logs-Url: https://github.com/fsprojects/FSharp.Data.GraphQL/sessions/313ed2f1-9407-4f24-8c8b-a0e2663bc4ee Co-authored-by: xperiandri <2365592+xperiandri@users.noreply.github.com>
Uh oh!
There was an error while loading. Please reload this page.